1. Field of the Invention
The present invention relates to pattern reference in the field of image processing techniques, and particularly relates to a technique for extracting a feature amount of a detection target pattern/recognition target pattern from an image in order to improve accuracy in pattern reference.
2. Description of the Related Art
Recently, a practical method has been proposed in a method for detecting a target pattern from an image through image processing. Particularly, various applications can be thought of when the target pattern is a human face, and therefore extensive research and development have been conducted for such a detection method. Furthermore, in addition to face detection itself, extensive research and development have also been conducted regarding a method of face recognition which identifies whose face the detected face belongs to among persons registered in advance.
A matching method is a technique frequently used in such a detection/recognition method. In the matching method, a degree of similarity is calculated by identification processing such as normalized correlation and the like executed between templates (registration images) provided in advance and a processing target image.
When applying face detection/face recognition using such a matching method in a real environment, such as a security system, there is the possibility that the contrast of image changes, or partial shades are generated in the image, due to changes in the weather and the time of day. In a real environment, appearances (patterns) in images change significantly according to such changes in light conditions, greatly affecting the detection accuracy/recognition accuracy.
To reduce such a problem, it has been proposed that a feature amount that is robust with respect to the changes in light is extracted from the luminance value, and the identification processing is executed on the feature amount, rather than executing the identification processing on the luminance value itself of the image. For example, a method in which correlation processing is executed on signs (Peripheral Increment Signs) of the luminance difference between a target pixel and surrounding pixels is discussed in Japanese Patent No. 3831232 (referred to as “Patent Document 1” hereinafter) and Sato, Kaneko, and Igarashi's “Robust Object Detection and Segmentation by Peripheral Increment Sign Correlation Image”, The Transactions of the Institute of Electronics, Information and Communication Engineers, D-II, Vol. J 84-D-II No. 12, pp. 2585-2594, December 2001 (referred to as “Non-Patent Document 1” hereinafter). In the method discussed in these documents, increments (magnitudes) in the gray value between the target pixel and the surrounding pixels in a template image and in a processing target image are expressed as signs, and the number of the matching signs are regarded as similarities. It is known that reference that is robust against brightness changes or the presence of noise in a range that does not reverse the signs can be executed using such a method.
However, the techniques discussed in Patent Document 1 and Non-Patent Document 1 calculate similarities between the template image and the processing target image. Therefore, when the detection target is broadened to, for example, a face, that is, an area that falls into a single category but that is individually characteristic, templates have to be prepared for each face type, making it difficult to put the techniques into practical usage.
Japanese Patent No. 3696212 (referred to as “Patent Document 2” hereinafter) and Japanese Patent Laid-Open No. 2006-185375 (referred to as “Patent Document 3” hereinafter) attempt to solve such a problem by extracting statistical characteristics of the peripheral increment signs from a database of detection target images (for example, various face images).
As another feature extraction similar to the peripheral increment sign technique, the LBP (Local Binary Pattern) operator is known, and a method using this LBP operator as preprocessing for removing the effects of changes in light on face recognition has been proposed as well (G. Heusch, Y. Rodriguez, and S. Marcel's “Local binary patterns as an image preprocessing for face authentication,” Automatic Face and Gesture Recognition, 2006. FGR 2006. 7th “International Conference on 10-12 Apr. 2006” (referred to as “Non-Patent Document 2” hereinafter)). The LBP operator for the pixel at position (xc, yc) is defined as the following formula. In the formula, “ic” represents the luminance value of the pixel at position (xc, yc), and “in” represents the luminance value of eight surrounding pixels. “n” represents an index of the surrounding pixels, where the index of the pixel in the upper left position to the position (xc, yc) is set to n=7, and the index decreases by one in the clockwise direction therefrom.
                                          LBP            ⁡                          (                                                x                  c                                ,                                  y                  c                                            )                                =                                    ∑                              n                =                0                            7                        ⁢                                                  ⁢                                          s                ⁡                                  (                                                            i                      n                                        -                                          i                      c                                                        )                                            ⁢                              2                n                                                    ⁢                                  ⁢                              s            ⁡                          (              x              )                                =                      {                                                            1                                                                                            if                      ⁢                                                                                          ⁢                      x                                        ≥                    0                                                                                                0                                                                                            if                      ⁢                                                                                          ⁢                      x                                        <                    0                                                                                                          [                  Formula          ⁢                                          ⁢          1                ]            
When the calculation target pixel (ic=96) at center position (xc, yc) and eight surrounding pixels are disposed as shown in FIG. 6A, 1 or 0 is assigned thereto based on their magnitude relations. FIG. 6B shows the result of the assignment. These assigned numbers of 1 or 0 are called quantization values, in the sense that binary quantization is executed on the difference values. Furthermore, the LBP value is obtained by adding a weight of a power of two to these quantization values. In Non-Patent Document 2, face recognition processing is executed for an image made up of the LBP values thus obtained.
However, problems such as those described below arise in Patent Document 2 and Patent Document 3, which execute face detection using the peripheral increment signs, and in Non-Patent Document 2, which executes face recognition using the LBP.
In Non-Patent Document 2, a weight of a power of two is assigned to the quantization values according to the relative positions of the calculation target pixel and surrounding eight pixels. To be specific, a weight of 128 is assigned to the pixel in the upper left relative to the calculation target pixel, and a weight of 64 is given to the pixel directly above the calculation target pixel, and subsequently, weights of 32, 16, 8, 4, 2, and 1 are assigned in the clockwise direction.
However, such a weight assignment of a power of two in the clockwise direction from the upper left pixel is not necessarily reasonable. For example, when a user wants to detect a pattern with many edges extending in the horizontal direction (horizontal stripes and the like) as the detection target, it can be expected that the detection performance improves when a greater weight is assigned in a direction that embodies the characteristics of the detection target. Additionally, the value for the weighting does not necessary has to be a power of two.
Furthermore, there is a case when a user wants to detect a pattern including many edges extending in the horizontal direction in a certain area (for example, around the eyes) and many edges extending in the vertical direction in another area (for example, around the nose) in an image such as a face as the detection target. In such a case, improvement in detection performance can be expected when the weighting on the directions is changed on a regional basis.
However, in Non-Patent Document 2, no consideration is given to such changing of weighting according to the characteristics of the detection target as described above, and further to changing of weighting according to partial regions of the detection target.
Furthermore, in Patent Document 2, an attempt has been made to capture the characteristics of the detection target by measuring the probability of occurrence of the increment signs, for each direction of the increment signs, and for the quantization values, using a database made up of detection target images. Furthermore, in Patent Document 3, an attempt has been made to capture the characteristics of the detection target by vectorizing the peripheral increment signs, for each direction of the increment signs, and for the quantization value, using a database made up of the images of the detection target images; and measuring the probability of occurrence for each vector.
However, when detecting a target pattern with the methods in Patent Document 2 or Patent Document 3, it is necessary to hold the probabilities of occurrence measured using the database as a table. Therefore, there is a problem in that particularly when the detection processing is executed using hardware, the amount of memory required to realize the table increases.
Particularly, when applying the method in Patent Document 2 or Patent Document 3 to a face recognition method in which a person is identified by his/her face out of persons registered in advance, there is a problem in that the number of tables increases in proportion with the number of persons registered. Furthermore, there is a problem in that sufficient images (images including the registered person) for calculating the reliable probability of occurrence are necessary for respective registered persons.